<template>
    <div>
        <div class="data-hte">
            <img src="@/assets/home_icon_logo.png">
        </div>
        <div class="data-kuang">
            <img src="https://hterobot-kimage.oss-cn-qingdao.aliyuncs.com/images1/right.png" alt="">
                <h5>恭喜您，绑定成功！</h5>
                <h6>{{guanbi}}秒后自动返回首页</h6>
                <p><a href="/">立即跳转</a></p>
        </div>
    </div>
</template>
<script>
    export default {
        data() {
            return{
                guanbi: 10
            }
        },
        watch:{
            guanbi: function (v) {
                if (v === 0) {
                   this.$router.push("/")
                }
            },
        },
        bbeforeRouteLeave (to, from, next) {
            next(clearInterval(this.gujianjian) )
        },
        mounted(){
     
             setInterval(this.gujianjian, 1000)
        },
        methods:{
            gujianjian: function () {
                this.guanbi--
            },
        }
    }
</script>
<style>
    .data-hte{
        width: 100%;
        height: 75px;
        box-shadow: 0px 0px 20px 0px 
		rgba(0, 0, 0, 0.1);
        margin-bottom: 135px;
        text-align: center;
        line-height: 75px;
    }
    .data-kuang{
        width: 207px;
        height: 212px;
        text-align: center;
        margin: 0 auto;
    }
    h5{
        text-align: center;
        font-family: MicrosoftYaHeiLight;
	font-weight: normal;
	font-stretch: normal;
	letter-spacing: 1px;
	color: #464444;
    }
    h6{
        text-align: center;
    }
    .data-kuang p{
        text-align: center;
    }
</style>